1. Field of the Invention
The present invention generally relates to computer systems and, more particularly, to an apparatus for keeping several versions of a file (e.g., user files and system files) in the computer""s memory unit (e.g., disk drive).
2. Description of the Related Art
In a computer system, when a user needs to modify a file, the initial version of this file which is stored in a memory is put at his disposal. Then, the user can modify this version, thereby producing a current version. When the work is done, the user closes the file and the system typically asks him if he wants to save the current version. When the answer is xe2x80x9cnoxe2x80x9d, the current version is deleted. When the answer is xe2x80x9cyesxe2x80x9d, the current version is substituted for the initial version. If the modification of the initial version (e.g., the current version) is not correct, it is not possible in conventional systems to come back to the initial version because it has been replaced. In fact, only one version is stored temporarily, and both versions are concurrently available exclusively during the modification.
At the present time, the only way to avoid this problem requires the user to make a copy of the initial version into another file prior to making any modification. This is not very user friendly and moreover, the user could easily forget to delete the duplicated file, which leads to unnecessary files occupying of the available memory space.
Recent computer systems generally come with a backup system. Such a system saves a defined set of files at regular time intervals, often during the night. But this system cannot solve the above-mentioned problem if the storing of the erroneous version and the creation of the initial version were both realized between two backup procedures. Furthermore, any file recovery from a backup recording is quite complex.
In view of the foregoing and other problems, disadvantages, and drawbacks of the conventional computer systems, an object of the present invention is to provide a structure and method for an apparatus which solves the drawbacks due to the storing of an erroneous version.
According to an embodiment of the invention, an apparatus is provided for keeping several versions of a file. An initial version (e.g., first version) of the file is stored in a first area (e.g., called xe2x80x9cold areaxe2x80x9d), and a current version (e.g., second version) is stored in a second area (e.g., called xe2x80x9ccurrent areaxe2x80x9d), the second version being a modification of the initial version. The apparatus comprises an overwriting unit for substituting the current version for the initial version in response to a validation signal, and more specifically, the validation signal is produced after the current version has been permanently stored.
Thus, prior to any validation, both versions are available and it is possible to restore the initial version when the current version is erroneous.
In addition, for a further version resulting from a modification of the current version, the apparatus comprises a unit for storing the current version in a third area (e.g., called xe2x80x9chistory areaxe2x80x9d) prior to this modification, this further version then becoming the current version. Advantageously, the apparatus comprises a correcting unit for replacing the current version by any previous version in response to a command.
Accordingly, the apparatus comprises an identification unit for identifying the current version prior to its replacement by the previous version. Moreover, the apparatus comprises a unit for deleting all versions stored in the history area in response to the validation signal. In one embodiment, the validation signal is an input signal.
Further, the apparatus may comprise a comparing unit for producing a comparison signal as a result of a comparison between the current version and another version. For instance, the validation signal corresponds to the comparison signal. Preferably, the apparatus comprises a unit for listing all versions.
In addition, the apparatus comprises a unit for restricting the number of versions stored in the history area. Likewise, the apparatus comprises a unit for deleting an identified version of the history area.
The present disclosure relates to subject matter contained in European Patent Application No. 99480002.7, filed Jan. 29, 1999, which is expressly incorporated herein by reference in its entirety.